```html
<!DOCTYPE html>
<html lang="zh-CN">
<head>
    <meta charset="UTF-8">
    <meta name="viewport" content="width=device-width, initial-scale=1.0">
    <title>健康数据可视化分析</title>
    <link href="https://fonts.googleapis.com/css2?family=Noto+Serif+SC:wght@400;500;600;700&family=Noto+Sans+SC:wght@300;400;500;700&display=swap" rel="stylesheet">
    <link href="https://cdn.staticfile.org/font-awesome/6.4.0/css/all.min.css" rel="stylesheet">
    <link href="https://cdn.staticfile.org/tailwindcss/2.2.19/tailwind.min.css" rel="stylesheet">
    <script src="https://cdn.jsdelivr.net/npm/chart.js"></script>
    <script src="https://cdn.jsdelivr.net/npm/mermaid@latest/dist/mermaid.min.js"></script>
    <style>
        body {
            font-family: 'Noto Sans SC', sans-serif;
            color: #333;
            background-color: #f9fafb;
            line-height: 1.6;
        }
        .hero {
            background: linear-gradient(135deg, #6b46c1 0%, #4299e1 100%);
            color: white;
        }
        .health-card {
            transition: all 0.3s ease;
            border-radius: 12px;
            overflow: hidden;
            box-shadow: 0 4px 6px rgba(0, 0, 0, 0.05);
        }
        .health-card:hover {
            transform: translateY(-5px);
            box-shadow: 0 10px 15px rgba(0, 0, 0, 0.1);
        }
        .indicator-row:hover {
            background-color: #f0f4f8;
            cursor: pointer;
        }
        .tab-active {
            border-bottom: 3px solid #6b46c1;
            color: #6b46c1;
            font-weight: 500;
        }
        .progress-ring__circle {
            transition: stroke-dashoffset 0.8s ease;
            transform: rotate(-90deg);
            transform-origin: 50% 50%;
        }
        .tooltip:hover .tooltip-text {
            visibility: visible;
            opacity: 1;
        }
    </style>
</head>
<body class="antialiased">
    <!-- Hero Section -->
    <section class="hero py-20 px-4 md:px-0">
        <div class="container mx-auto max-w-5xl text-center">
            <h1 class="text-4xl md:text-5xl font-bold mb-6 leading-tight">您的健康数据可视化分析</h1>
            <p class="text-xl md:text-2xl font-light max-w-3xl mx-auto mb-8">基于体检报告的专业健康评估与个性化改善建议</p>
            <div class="flex justify-center space-x-4">
                <div class="w-24 h-24 rounded-full bg-white bg-opacity-20 flex items-center justify-center">
                    <div class="relative w-20 h-20">
                        <svg class="progress-ring w-20 h-20" viewBox="0 0 80 80">
                            <circle class="progress-ring__circle" stroke="#ffffff" stroke-width="6" fill="transparent" r="34" cx="40" cy="40" stroke-dasharray="213.63" stroke-dashoffset="64.09" />
                        </svg>
                        <div class="absolute inset-0 flex items-center justify-center text-white font-bold text-xl">76</div>
                    </div>
                </div>
            </div>
            <p class="mt-6 text-white text-opacity-90">综合健康评分</p>
        </div>
    </section>

    <!-- Main Content -->
    <div class="container mx-auto max-w-5xl px-4 md:px-0 py-12">
        <!-- Summary Cards -->
        <div class="grid grid-cols-1 md:grid-cols-3 gap-6 mb-12">
            <div class="health-card bg-white p-6">
                <div class="flex items-center mb-4">
                    <div class="w-12 h-12 rounded-full bg-indigo-100 text-indigo-600 flex items-center justify-center mr-4">
                        <i class="fas fa-heartbeat text-xl"></i>
                    </div>
                    <h3 class="text-lg font-semibold">异常指标</h3>
                </div>
                <p class="text-3xl font-bold text-indigo-600 mb-2">4</p>
                <p class="text-gray-600">需要关注的健康问题</p>
            </div>
            <div class="health-card bg-white p-6">
                <div class="flex items-center mb-4">
                    <div class="w-12 h-12 rounded-full bg-blue-100 text-blue-600 flex items-center justify-center mr-4">
                        <i class="fas fa-chart-line text-xl"></i>
                    </div>
                    <h3 class="text-lg font-semibold">改善进度</h3>
                </div>
                <p class="text-3xl font-bold text-blue-600 mb-2">3</p>
                <p class="text-gray-600">正在进行中的改善计划</p>
            </div>
            <div class="health-card bg-white p-6">
                <div class="flex items-center mb-4">
                    <div class="w-12 h-12 rounded-full bg-green-100 text-green-600 flex items-center justify-center mr-4">
                        <i class="fas fa-check-circle text-xl"></i>
                    </div>
                    <h3 class="text-lg font-semibold">已达标</h3>
                </div>
                <p class="text-3xl font-bold text-green-600 mb-2">2</p>
                <p class="text-gray-600">恢复正常的健康指标</p>
            </div>
        </div>

        <!-- Tabs -->
        <div class="border-b border-gray-200 mb-8">
            <nav class="-mb-px flex space-x-8">
                <a href="#" class="tab-active py-4 px-1 text-sm font-medium">健康指标</a>
                <a href="#" class="text-gray-500 hover:text-gray-700 py-4 px-1 text-sm font-medium">改善建议</a>
                <a href="#" class="text-gray-500 hover:text-gray-700 py-4 px-1 text-sm font-medium">监测计划</a>
                <a href="#" class="text-gray-500 hover:text-gray-700 py-4 px-1 text-sm font-medium">趋势分析</a>
            </nav>
        </div>

        <!-- Indicators Table -->
        <div class="bg-white shadow-sm rounded-lg overflow-hidden mb-12">
            <table class="min-w-full divide-y divide-gray-200">
                <thead class="bg-gray-50">
                    <tr>
                        <th scope="col" class="px-6 py-3 text-left text-xs font-medium text-gray-500 uppercase tracking-wider">指标名称</th>
                        <th scope="col" class="px-6 py-3 text-left text-xs font-medium text-gray-500 uppercase tracking-wider">您的数值</th>
                        <th scope="col" class="px-6 py-3 text-left text-xs font-medium text-gray-500 uppercase tracking-wider">参考范围</th>
                        <th scope="col" class="px-6 py-3 text-left text-xs font-medium text-gray-500 uppercase tracking-wider">健康评分</th>
                        <th scope="col" class="px-6 py-3 text-left text-xs font-medium text-gray-500 uppercase tracking-wider">状态</th>
                    </tr>
                </thead>
                <tbody class="bg-white divide-y divide-gray-200">
                    <tr class="indicator-row" onclick="showDetails('bmi')">
                        <td class="px-6 py-4 whitespace-nowrap">
                            <div class="flex items-center">
                                <div class="flex-shrink-0 h-10 w-10 rounded-full bg-indigo-100 flex items-center justify-center">
                                    <i class="fas fa-weight text-indigo-600"></i>
                                </div>
                                <div class="ml-4">
                                    <div class="text-sm font-medium text-gray-900">BMI指数</div>
                                </div>
                            </div>
                        </td>
                        <td class="px-6 py-4 whitespace-nowrap">
                            <div class="text-sm text-gray-900">26.8</div>
                        </td>
                        <td class="px-6 py-4 whitespace-nowrap">
                            <div class="text-sm text-gray-500">18.5-24.0</div>
                        </td>
                        <td class="px-6 py-4 whitespace-nowrap">
                            <div class="flex items-center">
                                <div class="w-16 h-2 bg-gray-200 rounded-full mr-2">
                                    <div class="h-2 bg-red-500 rounded-full" style="width: 65%"></div>
                                </div>
                                <span class="text-sm font-medium">65</span>
                            </div>
                        </td>
                        <td class="px-6 py-4 whitespace-nowrap">
                            <span class="px-2 inline-flex text-xs leading-5 font-semibold rounded-full bg-red-100 text-red-800">偏高</span>
                        </td>
                    </tr>
                    <tr class="indicator-row" onclick="showDetails('blood')">
                        <td class="px-6 py-4 whitespace-nowrap">
                            <div class="flex items-center">
                                <div class="flex-shrink-0 h-10 w-10 rounded-full bg-indigo-100 flex items-center justify-center">
                                    <i class="fas fa-tint text-indigo-600"></i>
                                </div>
                                <div class="ml-4">
                                    <div class="text-sm font-medium text-gray-900">血小板计数</div>
                                </div>
                            </div>
                        </td>
                        <td class="px-6 py-4 whitespace-nowrap">
                            <div class="text-sm text-gray-900">95×10⁹/L</div>
                        </td>
                        <td class="px-6 py-4 whitespace-nowrap">
                            <div class="text-sm text-gray-500">100-300×10⁹/L</div>
                        </td>
                        <td class="px-6 py-4 whitespace-nowrap">
                            <div class="flex items-center">
                                <div class="w-16 h-2 bg-gray-200 rounded-full mr-2">
                                    <div class="h-2 bg-yellow-500 rounded-full" style="width: 80%"></div>
                                </div>
                                <span class="text-sm font-medium">80</span>
                            </div>
                        </td>
                        <td class="px-6 py-4 whitespace-nowrap">
                            <span class="px-2 inline-flex text-xs leading-5 font-semibold rounded-full bg-yellow-100 text-yellow-800">偏低</span>
                        </td>
                    </tr>
                    <tr class="indicator-row" onclick="showDetails('vision')">
                        <td class="px-6 py-4 whitespace-nowrap">
                            <div class="flex items-center">
                                <div class="flex-shrink-0 h-10 w-10 rounded-full bg-indigo-100 flex items-center justify-center">
                                    <i class="fas fa-eye text-indigo-600"></i>
                                </div>
                                <div class="ml-4">
                                    <div class="text-sm font-medium text-gray-900">视力(左眼)</div>
                                </div>
                            </div>
                        </td>
                        <td class="px-6 py-4 whitespace-nowrap">
                            <div class="text-sm text-gray-900">4.6</div>
                        </td>
                        <td class="px-6 py-4 whitespace-nowrap">
                            <div class="text-sm text-gray-500">≥4.9</div>
                        </td>
                        <td class="px-6 py-4 whitespace-nowrap">
                            <div class="flex items-center">
                                <div class="w-16 h-2 bg-gray-200 rounded-full mr-2">
                                    <div class="h-2 bg-orange-500 rounded-full" style="width: 70%"></div>
                                </div>
                                <span class="text-sm font-medium">70</span>
                            </div>
                        </td>
                        <td class="px-6 py-4 whitespace-nowrap">
                            <span class="px-2 inline-flex text-xs leading-5 font-semibold rounded-full bg-orange-100 text-orange-800">下降</span>
                        </td>
                    </tr>
                    <tr class="indicator-row" onclick="showDetails('breast')">
                        <td class="px-6 py-4 whitespace-nowrap">
                            <div class="flex items-center">
                                <div class="flex-shrink-0 h-10 w-10 rounded-full bg-indigo-100 flex items-center justify-center">
                                    <i class="fas fa-female text-indigo-600"></i>
                                </div>
                                <div class="ml-4">
                                    <div class="text-sm font-medium text-gray-900">乳腺检查</div>
                                </div>
                            </div>
                        </td>
                        <td class="px-6 py-4 whitespace-nowrap">
                            <div class="text-sm text-gray-900">乳腺增生</div>
                        </td>
                        <td class="px-6 py-4 whitespace-nowrap">
                            <div class="text-sm text-gray-500">正常</div>
                        </td>
                        <td class="px-6 py-4 whitespace-nowrap">
                            <div class="flex items-center">
                                <div class="w-16 h-2 bg-gray-200 rounded-full mr-2">
                                    <div class="h-2 bg-blue-500 rounded-full" style="width: 85%"></div>
                                </div>
                                <span class="text-sm font-medium">85</span>
                            </div>
                        </td>
                        <td class="px-6 py-4 whitespace-nowrap">
                            <span class="px-2 inline-flex text-xs leading-5 font-semibold rounded-full bg-blue-100 text-blue-800">异常</span>
                        </td>
                    </tr>
                </tbody>
            </table>
        </div>

        <!-- Charts Section -->
        <div class="grid grid-cols-1 md:grid-cols-2 gap-8 mb-12">
            <div class="health-card bg-white p-6">
                <h3 class="text-lg font-semibold mb-4">健康指标评分</h3>
                <canvas id="scoreChart" height="250"></canvas>
            </div>
            <div class="health-card bg-white p-6">
                <h3 class="text-lg font-semibold mb-4">BMI趋势</h3>
                <canvas id="trendChart" height="250"></canvas>
            </div>
        </div>

        <!-- Data Input Section -->
        <div class="health-card bg-white p-6 mb-12">
            <h3 class="text-lg font-semibold mb-6">更新健康数据</h3>
            <form class="space-y-4">
                <div class="grid grid-cols-1 md:grid-cols-2 gap-6">
                    <div>
                        <label for="indicator" class="block text-sm font-medium text-gray-700 mb-1">选择指标</label>
                        <select id="indicator" name="indicator" class="w-full px-3 py-2 border border-gray-300 rounded-md shadow-sm focus:outline-none focus:ring-indigo-500 focus:border-indigo-500">
                            <option value="bmi">BMI指数</option>
                            <option value="blood">血小板计数</option>
                            <option value="vision">视力(左眼)</option>
                            <option value="breast">乳腺检查</option>
                        </select>
                    </div>
                    <div>
                        <label for="value" class="block text-sm font-medium text-gray-700 mb-1">当前数值</label>
                        <input type="text" id="value" name="value" class="w-full px-3 py-2 border border-gray-300 rounded-md shadow-sm focus:outline-none focus:ring-indigo-500 focus:border-indigo-500" placeholder="输入最新测量值">
                    </div>
                </div>
                <div>
                    <label for="date" class="block text-sm font-medium text-gray-700 mb-1">测量日期</label>
                    <input type="date" id="date" name="date" class="w-full px-3 py-2 border border-gray-300 rounded-md shadow-sm focus:outline-none focus:ring-indigo-500 focus:border-indigo-500">
                </div>
                <div class="pt-2">
                    <button type="button" onclick="updateData()" class="w-full flex justify-center py-2 px-4 border border-transparent rounded-md shadow-sm text-sm font-medium text-white bg-indigo-600 hover:bg-indigo-700 focus:outline-none focus:ring-2 focus:ring-offset-2 focus:ring-indigo-500">
                        更新数据
                    </button>
                </div>
            </form>
        </div>

        <!-- Mermaid Diagram -->
        <div class="health-card bg-white p-6">
            <h3 class="text-lg font-semibold mb-4">健康改善模型</h3>
            <div class="mermaid">
                graph TD
                A[体检异常指标] --> B[健康评估]
                B --> C[制定改善计划]
                C --> D[福格行为模型]
                D --> E[动机: 明确健康益处]
                D --> F[能力: 简单易行的行动]
                D --> G[触发: 执行时间/情境]
                E --> H[持续健康跟踪]
                F --> H
                G --> H
                H --> I[健康指标改善]
            </div>
        </div>
    </div>

    <!-- Details Modal -->
    <div id="detailsModal" class="fixed inset-0 overflow-y-auto hidden" aria-labelledby="modal-title" role="dialog" aria-modal="true">
        <div class="flex items-end justify-center min-h-screen pt-4 px-4 pb-20 text-center sm:block sm:p-0">
            <div class="fixed inset-0 bg-gray-500 bg-opacity-75 transition-opacity" aria-hidden="true"></div>
            <span class="hidden sm:inline-block sm:align-middle sm:h-screen" aria-hidden="true">&#8203;</span>
            <div class="inline-block align-bottom bg-white rounded-lg px-4 pt-5 pb-4 text-left overflow-hidden shadow-xl transform transition-all sm:my-8 sm:align-middle sm:max-w-2xl sm:w-full sm:p-6">
                <div>
                    <div class="mx-auto flex items-center justify-center h-12 w-12 rounded-full bg-indigo-100">
                        <i class="fas fa-info-circle text-indigo-600"></i>
                    </div>
                    <div class="mt-3 text-center sm:mt-5">
                        <h3 id="modalTitle" class="text-lg leading-6 font-medium text-gray-900">BMI指数健康建议</h3>
                        <div class="mt-2">
                            <div id="modalContent" class="text-sm text-gray-500">
                                <!-- Content will be dynamically inserted here -->
                            </div>
                        </div>
                    </div>
                </div>
                <div class="mt-5 sm:mt-6">
                    <button type="button" onclick="closeModal()" class="inline-flex justify-center w-full rounded-md border border-transparent shadow-sm px-4 py-2 bg-indigo-600 text-base font-medium text-white hover:bg-indigo-700 focus:outline-none focus:ring-2 focus:ring-offset-2 focus:ring-indigo-500 sm:text-sm">
                        关闭
                    </button>
                </div>
            </div>
        </div>
    </div>

    <script>
        // Initialize charts
        document.addEventListener('DOMContentLoaded', function() {
            // Score Chart
            const scoreCtx = document.getElementById('scoreChart').getContext('2d');
            const scoreChart = new Chart(scoreCtx, {
                type: 'bar',
                data: {
                    labels: ['BMI指数', '血小板计数', '视力(左眼)', '乳腺检查'],
                    datasets: [{
                        label: '健康评分',
                        data: [65, 80, 70, 85],
                        backgroundColor: [
                            'rgba(239, 68, 68, 0.7)',
                            'rgba(234, 179, 8, 0.7)',
                            'rgba(249, 115, 22, 0.7)',
                            'rgba(59, 130, 246, 0.7)'
                        ],
                        borderColor: [
                            'rgba(239, 68, 68, 1)',
                            'rgba(234, 179, 8, 1)',
                            'rgba(249, 115, 22, 1)',
                            'rgba(59, 130, 246, 1)'
                        ],
                        borderWidth: 1
                    }]
                },
                options: {
                    scales: {
                        y: {
                            beginAtZero: true,
                            max: 100,
                            ticks: {
                                stepSize: 20
                            }
                        }
                    },
                    plugins: {
                        legend: {
                            display: false
                        }
                    }
                }
            });

            // Trend Chart
            const trendCtx = document.getElementById('trendChart').getContext('2d');
            const trendChart = new Chart(trendCtx, {
                type: 'line',
                data: {
                    labels: ['1月', '2月', '3月', '4月', '5月', '6月'],
                    datasets: [{
                        label: 'BMI指数',
                        data: [27.2, 27.0, 26.8, 26.5, 26.3, 26.1],
                        fill: false,
                        backgroundColor: 'rgba(99, 102, 241, 0.2)',
                        borderColor: 'rgba(99, 102, 241, 1)',
                        tension: 0.1,
                        pointBackgroundColor: 'rgba(99, 102, 241, 1)',
                        pointRadius: 5,
                        pointHoverRadius: 7
                    }]
                },
                options: {
                    scales: {
                        y: {
                            beginAtZero: false,
                            min: 25,
                            max: 28
                        }
                    }
                }
            });

            // Initialize Mermaid
            mermaid.initialize({
                startOnLoad: true,
                theme: 'default',
                flowchart: {
                    useMaxWidth: true,
                    htmlLabels: true,
                    curve: 'basis'
                }
            });
        });

        // Modal functions
        function showDetails(indicator) {
            const modal = document.getElementById('detailsModal');
            const modalTitle = document.getElementById('modalTitle');
            const modalContent = document.getElementById('modalContent');
            
            let title = '';
            let content = '';
            
            switch(indicator) {
                case 'bmi':
                    title = 'BMI指数健康建议';
                    content = `
                        <div class="space-y-4">
                            <div>
                                <h4 class="font-medium">健康风险:</h4>
                                <p>BMI超标可能增加心血管疾病、糖尿病和关节负担风险。</p>
                            </div>
                            <div>
                                <h4 class="font-medium">改善建议 (基于福格行为模型):</h4>
                                <ul class="list-disc pl-5 space-y-2">
                                    <li><strong>动机:</strong> 每减重5%可显著降低慢性病风险</li>
                                    <li><strong>能力:</strong> 
                                        <ol class="list-decimal pl-5 mt-1 space-y-1">
                                            <li>每周3次30分钟快走</li>
                                            <li>晚餐减少1/3主食量</li>
                                            <li>用水果替代零食</li>
                                        </ol>
                                    </li>
                                    <li><strong>触发:</strong> 设置手机每日19:00运动提醒</li>
                                </ul>
                            </div>
                            <div>
                                <h4 class="font-medium">监测计划:</h4>
                                <ul class="list-disc pl-5 space-y-1">
                                    <li><strong>每日:</strong> 薄荷健康APP记录饮食和运动</li>
                                    <li><strong>每周:</strong> 固定时间测量体重</li>
                                    <li><strong>每月:</strong> 腰围测量和记录</li>
                                </ul>
                            </div>
                        </div>
                    `;
                    break;
                case 'blood':
                    title = '血小板计数健康建议';
                    content = `
                        <div class="space-y-4">
                            <div>
                                <h4 class="font-medium">健康风险:</h4>
                                <p>血小板偏低可能导致出血倾向，需排查原因并关注症状。</p>
                            </div>
                            <div>
                                <h4 class="font-medium">改善建议 (基于福格行为模型):</h4>
                                <ul class="list-disc pl-5 space-y-2">
                                    <li><strong>动机:</strong> 维持正常血小板水平保障凝血功能</li>
                                    <li><strong>能力:</strong> 
                                        <ol class="list-decimal pl-5 mt-1 space-y-1">
                                            <li>增加富含维生素K的食物(菠菜、西兰花)</li>
                                            <li>避免剧烈运动和可能造成外伤的活动</li>
                                            <li>保证充足睡眠</li>
                                        </ol>
                                    </li>
                                    <li><strong>触发:</strong> 设置每周一早餐吃绿叶蔬菜提醒</li>
                                </ul>
                            </div>
                            <div>
                                <h4 class="font-medium">监测计划:</h4>
                                <ul class="list-disc pl-5 space-y-1">
                                    <li><strong>每日:</strong> 观察是否有异常出血或淤青</li>
                                    <li><strong>每月:</strong> 血常规复查</li>
                                    <li><strong>医生随访:</strong> 3个月后血液科复诊</li>
                                </ul>
                            </div>
                        </div>
                    `;
                    break;
                case 'vision':
                    title = '视力健康建议';
                    content = `
                        <div class="space-y-4">
                            <div>
                                <h4 class="font-medium">健康风险:</h4>
                                <p>视力下降影响生活质量，可能由用眼过度或近视发展导致。</p>
                            </div>
                            <div>
                                <h4 class="font-medium">改善建议 (基于福格行为模型):</h4>
                                <ul class="list-disc pl-5 space-y-2">
                                    <li><strong>动机:</strong> 保护视力可延缓近视发展，减少眼部不适</li>
                                    <li><strong>能力:</strong> 
                                        <ol class="list-decimal pl-5 mt-1 space-y-1">
                                            <li>每用眼40分钟远眺5分钟</li>
                                            <li>调整屏幕亮度和环境光线匹配</li>
                                            <li>每日热敷眼部5分钟</li>
                                        </ol>
                                    </li>
                                    <li><strong>触发:</strong> 设置电脑每小时提醒休息</li>
                                </ul>
                            </div>
                            <div>
                                <h4 class="font-medium">监测计划:</h4>
                                <ul class="list-disc pl-5 space-y-1">
                                    <li><strong>每日:</strong> 记录用眼时间和休息情况</li>
                                    <li><strong>每周:</strong> 检查视力表自测</li>
                                    <li><strong>每半年:</strong> 专业眼科检查</li>
                                </ul>
                            </div>
                        </div>
                    `;
                    break;
                case 'breast':
                    title = '乳腺健康建议';
                    content = `
                        <div class="space-y-4">
                            <div>
                                <h4 class="font-medium">健康风险:</h4>
                                <p>乳腺增生常见于育龄女性，需定期监测排除异常变化。</p>
                            </div>
                            <div>
                                <h4 class="font-medium">改善建议 (基于福格行为模型):</h4>
                                <ul class="list-disc pl-5 space-y-2">
                                    <li><strong>动机:</strong> 规律检查可早期发现乳腺异常</li>
                                    <li><strong>能力:</strong> 
                                        <ol class="list-decimal pl-5 mt-1 space-y-1">
                                            <li>每月月经后7-10天自检乳房</li>
                                            <li>减少咖啡因和高脂饮食摄入</li>
                                            <li>穿戴合适支撑内衣</li>
                                        </ol>
                                    </li>
                                    <li><strong>触发:</strong> 手机日历设置每月提醒自检</li>
                                </ul>
                            </div>
                            <div>
                                <h4 class="font-medium">监测计划:</h4>
                                <ul class="list-disc pl-5 space-y-1">
                                    <li><strong>每月:</strong> 乳腺自检(使用美柚APP记录)</li>
                                    <li><strong>每半年:</strong> 乳腺超声检查</li>
                                    <li><strong>每年:</strong> 乳腺专科医生检查</li>
                                </ul>
                            </div>
                        </div>
                    `;
                    break;
            }
            
            modalTitle.textContent = title;
            modalContent.innerHTML = content;
            modal.classList.remove('hidden');
        }

        function closeModal() {
            document.getElementById('detailsModal').classList.add('hidden');
        }

        // Update data function
        function updateData() {
            const indicatorSelect = document.getElementById('indicator');
            const valueInput = document.getElementById('value');
            const dateInput = document.getElementById('date');
            
            alert(`数据已更新:\n指标: ${indicatorSelect.options[indicatorSelect.selectedIndex].text}\n数值: ${valueInput.value}\n日期: ${dateInput.value}`);
            
            // In a real application, you would update the charts and tables here
            valueInput.value = '';
            dateInput.value = '';
        }
    </script>
</body>
</html>
```